<div class="sect3">
<h4 id="stage"><a class="anchor" href="#stage"></a>stage<a class="anchorjs-link " href="#stage" aria-label="Anchor link for: stage" data-anchorjs-icon="" style="font: 1em/1 anchorjs-icons; padding-left: 0.375em;"></a></h4>
<div class="paragraph">
<p>The <code>stage</code> directive goes in the <code>stages</code> section and should contain a
<a href="#steps">steps</a> section, an optional <code>agent</code> section, or other stage-specific directives.
Practically speaking, all of the real work done by a Pipeline will be wrapped
in one or more <code>stage</code> directives.</p>
</div>
<table class="tableblock frame-all grid-all stretch syntax">
<colgroup>
<col style="width: 10%;">
<col style="width: 90%;">
</colgroup>
<tbody>
<tr>
<th class="tableblock halign-center valign-top"><p class="tableblock">Required</p></th>
<td class="tableblock halign-right valign-top"><div class="content"><div class="paragraph">
<p>At least one</p>
</div></div></td>
</tr>
<tr>
<th class="tableblock halign-center valign-top"><p class="tableblock">Parameters</p></th>
<td class="tableblock halign-right valign-top"><div class="content"><div class="paragraph">
<p>One mandatory parameter, a string for the name of the stage.</p>
</div></div></td>
</tr>
<tr>
<th class="tableblock halign-center valign-top"><p class="tableblock">Allowed</p></th>
<td class="tableblock halign-right valign-top"><div class="content"><div class="paragraph">
<p>Inside the <code>stages</code> section.</p>
</div></div></td>
</tr>
</tbody>
</table>
<div class="sect4">
<h5 id="stage-example"><a class="anchor" href="#stage-example"></a>Example<a class="anchorjs-link " href="#stage-example" aria-label="Anchor link for: stage example" data-anchorjs-icon="" style="font: 1em/1 anchorjs-icons; padding-left: 0.375em;"></a></h5>
<div class="pipeline-block">  <div class="listingblock pipeline-declarative">
    <div class="title">Jenkinsfile (Declarative Pipeline)</div>
    <div class="content">
  <pre class="CodeRay highlight nowrap"><code class="language-groovy" data-lang="groovy">pipeline {
    agent any
    stages {
        stage(<span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">'</span><span style="color:#D20">Example</span><span style="color:#710">'</span></span>) {
            steps {
                echo <span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">'</span><span style="color:#D20">Hello World</span><span style="color:#710">'</span></span>
            }
        }
    }
}</code></pre>
</div></div></div>
</div>
</div>